const  jwt=require("jsonwebtoken")

module.exports=function (data){
  const token = jwt.sign({
    userId: data.userId
  }, "千锋H5", {
    expiresIn: 7 * 24 * 60 * 60
  });
  return token
}